1. Field of the Invention
The present invention relates generally to apparatus used in the field of computer-based system debugging, and more particularly to a relational break signal generating device for monitoring the execution of a computer program and causing the suspension of execution of that program and/or the initiation or termination of external processes as a function of the memory and/or I/O operations being performed by the programmer.
2. Description of the Prior Art
There has long been a need for apparatus capable of monitoring the execution of a computer program and halting the program and/or triggering external processes as a function of the execution of the program. One prior art method used is to replace a particular program instruction with a halt instruction so that if the computer tries to execute the instruction that normally resides at that particular point in the program, the execution sequence will be caused to stop and indicate the attempted instruction execution. This allows the programmer to run the program to a certain point and then examine the results of execution up to that point. By judicious replacement of certain instructions with the halt instructions, the programmer can thus control and monitor the execution of a program.
The problem with this prior art technique is that it cannot be used in software in which the program is stored in ROMs since it is not possible to replace an instruction in a ROM with a halt instruction.
Another prior art method is to place an instruction in the monitored program which will cause the computer to jump to a control program and allow easier access to memory. However, the problem with this technique is that the frequent jumping to a control program to log certain types of data, or to check and see if a break point condition has occurred, means that the program is not allowed to run in real time.
The present invention extends the concept of break point control to that of (a) relational breaks and (b) between limits breaks (break regions). Relational breaks are defined to include the following:
(1) If X=A, then break. PA1 (2) If X&gt;A, then break. PA1 (3) If X&lt;A, then break. PA1 (24) If X.gtoreq.A, then break. PA1 (5) If X.ltoreq.A, then break.
Thus, the equality break point (Case 1) is the most simple case of a relational break. Note that for efficiency of hardware realization, Cases 4 and 5 may be achieved by letting A=A'+1, in which case Case 4 is equivalent to Case 2, and letting A=A'-1, wherein Case 5 is equivalent to Case 3.
In the industry, break points are used to facilitate software debugging, hardware debugging and software/hardware debugging. The break point concept is used in logical analyzers (hardware), in-circuit emulation (hardware), monitors (computer program), debug executives (computer program) and the front panel of computers.
The generalization concept of break point to include relational points and breaks and break regions greatly improves the ability of an engineer to debug software, debug hardware, or debug hardware/software systems and make performance measurements within the computer system. The use of the relational break concept for software debugging increases the ability of the computer program to locate malfunctioning software by permitting him to establish a "window" around the portion of the computer program that is malfunctioning and then to "close in on the error" until the part of the program which is malfunctioning is located. This is to be contrasted with the use of a break point which requires considerably more user interaction and may necessitate single step execution of the program. In some cases it is practically impossible to use break point to determine an error due to the real time constraints within which the program must be executed.
The use of relational and regional breaks for hardware debugging is very powerful in the detection of intermittent hardware failure which causes the hardware to cease proper program execution erratically and unpredictably. Break points cannot be effectively used for this purpose because that technique requires that one know in advance where to place the break point.